//
//  CPSCAll2CategoryRightTitleHeaderView.m
//  CollTest
//
//  Created by codew on 11/11/21.
//

#import "CPSCAll2CategoryRightTitleHeaderView.h"

@interface CPSCAll2CategoryRightTitleHeaderView ()

@property (nonatomic, strong) UILabel *lblTitle;


@end

@implementation CPSCAll2CategoryRightTitleHeaderView


- (instancetype)initWithReuseIdentifier:(NSString *)reuseIdentifier {
    if (self = [super initWithReuseIdentifier: reuseIdentifier]) {
        [self initViews];
        [self makeContraints];
    }
    return self;
}

- (void)initViews {
    
    self.contentView.backgroundColor = [UIColor whiteColor];
//    self.contentView.backgroundColor = kCPSCRandomColor;
    [self.contentView addSubview: self.lblTitle];
    
}
- (void)makeContraints {
    
    [self.lblTitle mas_makeConstraints:^(MASConstraintMaker *make) {
        make.top.left.right.bottom.mas_equalTo(0);
    }];

}
- (UILabel *)lblTitle
{
    if (!_lblTitle) {
        
        UILabel * lblZy = [[UILabel alloc] init];
        lblZy.textColor = [UIColor colorWithHexString:@"#222222"];
        lblZy.font = [UIFont boldSystemFontOfSize:15];
        lblZy.textAlignment = NSTextAlignmentLeft;
        _lblTitle = lblZy;
    }
    
    return _lblTitle;
}



- (void)updateViewWithTitle:(NSString *)title
{
    self.lblTitle.text = title;
}


@end
